import 'package:taonile/generated/json/base/json_field.dart';
import 'package:taonile/generated/json/apply_business_info_entity.g.dart';
import 'dart:convert';

@JsonSerializable()
class ApplyBusinessInfoEntity {

	late int code=0;
	late String msg;
	late ApplyBusinessInfoData data;
  
  ApplyBusinessInfoEntity();

  factory ApplyBusinessInfoEntity.fromJson(Map<String, dynamic> json) => $ApplyBusinessInfoEntityFromJson(json);

  Map<String, dynamic> toJson() => $ApplyBusinessInfoEntityToJson(this);

  @override
  String toString() {
    return jsonEncode(this);
  }
}

@JsonSerializable()
class ApplyBusinessInfoData {

	late String id;
	@JSONField(name: "user_id")
	late String userId;
	late String type;
	late String name;
	late String province;
	late String city;
	late String area;
	@JSONField(name: "province_id")
	late String provinceId;
	@JSONField(name: "city_id")
	late String cityId;
	@JSONField(name: "area_id")
	late String areaId;
	late String address;
	late String lon;
	late String lat;
	late String logo;
	@JSONField(name: "category_id")
	late String categoryId;
	late String labels;
	@JSONField(name: "occupant_name")
	late String occupantName;
	@JSONField(name: "occupant_id")
	late String occupantId;
	@JSONField(name: "front_photo")
	late String frontPhoto;
	@JSONField(name: "back_photo")
	late String backPhoto;
	@JSONField(name: "is_certificates")
	late String isCertificates;
	@JSONField(name: "license_photo")
	late String licensePhoto;
	@JSONField(name: "credit_code")
	late String creditCode;
	@JSONField(name: "validity_type")
	late String validityType;
	@JSONField(name: "license_time")
	late String licenseTime;
	@JSONField(name: "factory_certificate")
	late String factoryCertificate;
	@JSONField(name: "inspection_report")
	late String inspectionReport;
	@JSONField(name: "approve_report")
	late String approveReport;
	@JSONField(name: "sanitary_permits")
	late String sanitaryPermits;
	late String status='';
	late String reason='';
	@JSONField(name: "created_at")
	late String createdAt;
	@JSONField(name: "updated_at")
	late String updatedAt;
	@JSONField(name: "category_name")
	late String categoryName;
  
  ApplyBusinessInfoData();

  factory ApplyBusinessInfoData.fromJson(Map<String, dynamic> json) => $ApplyBusinessInfoDataFromJson(json);

  Map<String, dynamic> toJson() => $ApplyBusinessInfoDataToJson(this);

  @override
  String toString() {
    return jsonEncode(this);
  }
}